﻿
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace LxCFD
{
    public class DensityBase : Value1Base<double>
    {
        protected FvFace[] faces;
        protected FvCell[] cells;
        protected double[] cellDensity;
        protected double[] faceDensity;
        public virtual void createArray(FvZone zone)
        {
            this.faces = zone.Faces;
            this.cells = zone.Cells;
        }
        public void calFaceDensity()
        {
            for (int i1 = 0; i1 < faces.Length; i1++)
            {
                faceDensity[i1] = faces[i1].CalAverage(cellDensity);
            }
        }
    }
    public class IdeaGassDensity : DensityBase
    {
        double[] T;
        double[] P;
        public void setParameter(double[] Temperature, double[] Pressure)
        {
            this.T = Temperature;
            this.P = Pressure;
        }
        public void calCellDensity()
        {
            for (int i1 = 0; i1 < cells.Length; i1++)
            {
                //cellDensity[i1] = ;
            }
        }
    }
}
